/**
rs_common 设备的定义
*/

#pragma once

#include <math.h>
#include <atomic>
#include <cstring>
#include <fstream>
#include <iomanip>
#include <mutex>
#include <thread>
#include <string>


class rsCmmonDevice
{
private:
    std::string device_name;                      
public:
    rsCmmonDevice(const std::string& _device_name): device_name(_device_name){}
    ~rsCmmonDevice(){}

    virtual void start() = 0;                           // 开启设备
    virtual void stop() = 0;                            // 关闭设备
    virtual bool setExposure(double exposure) = 0;      // 设置曝光
    virtual void setSkipFrames(int skip) = 0;           // 设置跳过的frames
    virtual void setWebpQuality(int quality) = 0;

public:


    bool manual_exposure;      // 是否是手动曝光
    int skip_frames = 2;      // 跳过的图像数量
    int webp_quality;     
    int frame_counter = 0;     // 图像数量

    int IMG_ROW = 640;
    int IMG_COL = 480;
    int FPS = 60;

};

